<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

</body>
<script>
    function Person(name,age,gender) {
        this.age = age;
        this.name =name;
        this.gender= gender;
        this.sayName=function () {
            console.log(this.name)
        }
    }
    var person = new Person('xqz',21,'man');
    person.sayName()
</script>
</html>
